using System;

namespace EventBus
{
    /// <summary>
    /// 监听方是Action的方式处理事件
    /// </summary>
    public interface IEventListenerAction
    {
        /// <summary>
        /// 监听指定的事件
        /// </summary>
        /// <param name="eventName">事件名</param>
        /// <param name="callback">回调函数</param>
        void Listen(string eventName, Action callback);
        void Listen<T>(string eventName, Action<T> callback);
        void Listen<T1, T2>(string eventName, Action<T1, T2> callback);
        void Listen<T1, T2, T3>(string eventName, Action<T1, T2, T3> callback);
        void Listen<T1, T2, T3, T4>(string eventName, Action<T1, T2, T3, T4> callback);
        void Listen<T1, T2, T3, T4, T5>(string eventName, Action<T1, T2, T3, T4, T5> callback);
        void Listen<T1, T2, T3, T4, T5, T6>(string eventName, Action<T1, T2, T3, T4, T5, T6> callback);
        void Listen<T1, T2, T3, T4, T5, T6, T7>(string eventName, Action<T1, T2, T3, T4, T5, T6, T7> callback);
        void Listen<T1, T2, T3, T4, T5, T6, T7, T8>(string eventName, Action<T1, T2, T3, T4, T5, T6, T7, T8> callback);
    }
}